package jmcnet.libcommun.jmcnetds;

import org.apache.commons.beanutils.PropertyUtils;
import org.apache.log4j.Logger;

public abstract class JMCNetDS_AbstractService implements JMCNetDS_Service {
	private Logger log = Logger.getLogger(JMCNetDS_AbstractService.class);
	
	public void copyFromXmlToVo(Object xmlVo, Object actionVo) throws Exception {
		PropertyUtils.copyProperties(actionVo, xmlVo);
	}

	public void onError(String serviceName, Object serviceData, Exception exc)
			throws Exception {
		log.error("onError serviceName="+serviceName+" serviceData="+serviceData, exc);
	}

	public void postRequestProcessing(String serviceName, String repXmlStr)
			throws Exception {
		log.info("postRequestProcessing serviceName="+serviceName+" repXmlStr="+repXmlStr);
	}

	public void preRequestProcessing(String serviceName, Object data, Object actionVo)
			throws Exception {
		log.info("Appel preRequestProcessing serviceName="+serviceName+" data="+data);
	}

}
